RenWuGuide={}
RenWuGuide.state=-1
RenWuGuide.showRenWu = function(self)
  setTouchEnabledAll(MainScene.node, false)
  --MainScene.addMask(1003)
  setTouchEnabledAll(MainScene.mainui:getChildByTag(1020), true)
end
RenWuGuide.go = function(self)
  print("RenWuGuide.go", RenWuScene.instance, RenWuScene.instance.curGoButtons)
  setTouchEnabledAll(RenWuScene.instance.node, false)
  TypeCast(RenWuScene.instance.curGoButtons[1], "CCButton"):setEnabled(true)
end 
RenWuGuide.fight = function(self)
  setTouchEnabledAll(ZhanDouScene.instance.node, false)
  TypeCast(ZhanDouScene.instance.checkpointButtons[1], "CCButton"):setEnabled(true)
end
RenWuGuide.fightEnd = function(self)
  setTouchEnabledAll(WarResultScene.layer, false)
  TypeCast(WarResultScene.layer:getChildByTag(1111), "CCButton"):setEnabled(true)
end
RenWuGuide.backZhanDouScene = function(self)
  setTouchEnabledAll(ZhanDouScene.instance.node, false)
  TypeCast(ZhanDouScene.instance.node:getChildByTag(1001), "CCButton"):setEnabled(true)
end
--RenWuGuide.showRenWuAgain = function(self)
--end
RenWuGuide.getAward = function(self)
  setTouchEnabledAll(RenWuScene.instance.node, false)
  TypeCast(RenWuScene.instance.node:getChildByTag(1020), "CCButton"):setEnabled(true)
end
RenWuGuide.close = function(self)
  setTouchEnabledAll(RenWuScene.instance.node, false)
  TypeCast(RenWuScene.instance.node:getChildByTag(1111), "CCButton"):setEnabled(true)
end
RenWuGuide.nextStep = function(self)
  print("RenWuGuide.nextStep", RenWuGuide.state)
  if RenWuGuide.state==-1 then
    RenWuGuide.showRenWu()    
    RenWuGuide.state=0
  elseif RenWuGuide.state==0 then
    RenWuGuide.go()
    RenWuGuide.state=1
  elseif RenWuGuide.state==1 then
    RenWuGuide.fight()
    RenWuGuide.state=2
  elseif RenWuGuide.state==2 then
    RenWuGuide.fightEnd()
    RenWuGuide.state=3
  elseif RenWuGuide.state==3 then
    RenWuGuide.backZhanDouScene()
    RenWuGuide.state=4
  elseif RenWuGuide.state==4 then
    RenWuGuide.showRenWu()
    RenWuGuide.state=5
  elseif RenWuGuide.state==5 then
    RenWuGuide.getAward()
    RenWuGuide.state=6
  elseif RenWuGuide.state==6 then
    RenWuGuide.close() 
    RenWuGuide.state=7
  end
end
